﻿@model IEnumerable<BskLeague.Models.AnnounceCommunicate>

@{
    ViewBag.Title = "Zgłoszenia";
}

@Html.Partial("_Submenu", (BskLeague.Models.Player) ViewBag.player)

<h3>Zgłoszenia</h3>


<table>
    <tr>
        <th>
            Nazwa drużyny
        </th>
        <th>
            Data zgłoszenia
        </th>
        <th>
            Kapitan
        </th>

        <th>
            Opcje
        </th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.TeamName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.AnnounceDate)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Players[item.ChefPlayerIndex].Name)
            @Html.DisplayFor(modelItem => item.Players[item.ChefPlayerIndex].Surname)
        </td>
        <td>
            @Html.ActionLink("Potwierdź", "ConfirmAnnouncement", new { id=item.AnnounceCommunicateId })
        </td>
    </tr>
}

</table>
